From: Jan Beulich Date: Wed, 27 Mar 2013 07:46:28 +0000 (+0100) Subject: x86/EFI: permit setting variable with non-zero attributes X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~7077 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/%22bookmarks://%22/%22http:/www.example.com/cgi/%22https:/%22bookmarks:/%22?a=commitdiff_plain;h=78380c34dfeb27da3d0222bcb7232c5d8e2f5b30;p=xen.git x86/EFI: permit setting variable with non-zero attributes This must have been a copy-and-paste mistake - get_variable uses op->misc as output only, and wants to make sure it's zero for future extensibility. For set_variable, this is an input though, and hence the check is wrong. Signed-off-by: Jan Beulich Acked-by: Keir Fraser --- diff --git a/xen/arch/x86/efi/runtime.c b/xen/arch/x86/efi/runtime.c index 73aa15eb9a..aafdfebdd8 100644 --- a/xen/arch/x86/efi/runtime.c +++ b/xen/arch/x86/efi/runtime.c @@ -398,9 +398,6 @@ int efi_runtime_call(struct xenpf_efi_runtime_call *op) long len; unsigned char *data; - if ( op->misc ) - return -EINVAL; - len = gwstrlen(guest_handle_cast(op->u.set_variable.name, CHAR16)); if ( len < 0 ) return len;